<!doctype html>
<html>
<head>
  <meta charset="utf-8">
  <title>工程安全信息化管理系统</title>
  <meta name="description" content="">
  <!-- <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"> -->
  <link rel="shortcut icon" href="favicon.ico" type="image/x-icon">
  {% for (var css in o.htmlWebpackPlugin.files.css) { %}
  <link href="{%=o.htmlWebpackPlugin.files.css[css] %}" rel="stylesheet">
  {% } %}

  {% for (var chunk in o.htmlWebpackPlugin.files.chunks) { %}
  <script src="{%=o.htmlWebpackPlugin.files.chunks[chunk].entry %}" defer></script>
  {% } %}

  <script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=ryGGzhrZxutxxgj6q4TPjUGq"></script>
  <script type="text/javascript" src="http://api.map.baidu.com/library/LuShu/1.2/src/LuShu_min.js"></script>
</head>
<body>
  <!--[if lt IE 8]>
  <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
  <![endif]-->
  <div class="page">
    <header-nav
      ng-show="!($state.current.name == 'login' || $state.current.name == 'forgetPwd')"></header-nav>
    <div ui-view class="main-right-content"></div>
  </div>
  
  <!-- confirm 弹窗 -->
  <script type="text/ng-template" id="paConfirm">
    <div class="pa-dialog" style="width: 400px;">
      <div class="pa-dialog-header">
        <div class="title-txt">
          <span>{{modalTitle}}</span>
        </div>
      </div>
      <div class="pa-dialog-content">
        <div class="">{{modalContent}}</div>           
      </div>
      <div class="pa-dialog-footer"
       ng-click="confirm()">
        <a class="pa-btn">
          <i class="fa fa-save"></i>
          <span>确定</span>
        </a>
        <a class="pa-btn" ng-click="closeThisDialog()">
          <i class="fa fa-times"></i>
          <span>取消</span>
        </a>
      </div>
    </div>
  </script>

  <!-- 问题内容详情 css 在dailyCheck.scss-->
  <script type="text/ng-template" id="rectification">
    <div class="item-detail-dialog training-tech">
      <div class="item-detail-dialog-header">
        <div class="title-txt">
          <span>内容详情</span>
        </div>
      </div>
      <div class="rectification-detail main">
        <!-- 展示需要整改问题 -->
        <div class="issue-detail-container shadowbox">
          <div class="title">
            <div class="title-txt">
              <i class="fa fa-pencil-square-o"></i>
              <span>内容说明</span>
            </div>
          </div>
          <div class="content">
            <div class="row-dash">
              <div class="row-item">
                <span class="item-label">内容编号：</span>
                <span class="item-value red-txt">
                  {{rectificationDetail.detailList.contentNumber}}
                </span>
              </div>
              <div class="row-item">
                <span class="item-label">巡查记录：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.taskName}}
                </span>
              </div>
            </div>
            <div class="row-dash">
              <div class="row-item">
                <span class="item-label">巡查分类：</span>
                <span class="item-value red-txt">
                  {{rectificationDetail.detailList.checkClassifyName}}
                </span>
              </div>
              <div class="row-item">
                <span class="item-label">提交时间：</span>
                <span class="item-value red-txt">
                  {{rectificationDetail.detailList.problemFoundTime1}}
                </span>
              </div>
            </div>
            <div class="row-dash">
              <div class="row-item">
                <span class="item-label">巡查人：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.problemFoundUser}}
                </span>
              </div>
              <div class="row-item">
                <span class="item-label">巡查单位：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.responsibilityUnit}}
                </span>
              </div>
            </div>
            <div class="row-dash">
              <div class="row-item">
                <span class="item-label">巡查地点：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.bidName}}
                </span>
              </div>
              <div class="row-item">
                <span class="item-label">施工队：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.teamName}}
                </span>
              </div>
            </div>
            <div class="row-dash"
              ng-hide="rectificationDetail.detailList.problemStatus == 3">
              <div class="row-item">
                <span class="multiple-rows-label">整改期限：</span>
                <span class="multiple-rows-value">
                  {{rectificationDetail.detailList.problemDeadline1}}
                </span>
              </div>
            </div>
            <div class="row-dash"
              ng-hide="rectificationDetail.detailList.problemStatus == 3">
              <div class="row-item" style="width: 100%;">
                <span class="item-label">内容场景：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.problemScenarios}}
                </span>
              </div>
            </div>
            <div class="row-dash">
              <div class="row-item">
                <span class="item-label">描述：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.problemDescription}}
                </span>
              </div>
            </div>
            <div class="issue-pics">
              <div class="issue-pics-title">照片</div>
              <div class="issue-pics-container">
                <img
                  ng-repeat="item in rectificationDetail.detailList.fileBeanList" 
                  ng-src="{{serverIp}}/{{item.filePath}}"
                  ng-click="rectificationDetail.preview(item)">
              </div>
            </div>
          </div>
        </div>

        <!-- 展示整改完成情况 -->
        <div class="issue-detail-container shadowbox" 
          ng-hide="rectificationDetail.detailList.problemStatus == 0 || rectificationDetail.detailList.problemStatus == 3">
          <div class="title">
            <div class="title-txt">
              <i class="fa fa-wrench"></i>
              <span>整改情况</span>
            </div>
          </div>
          <div class="content">
            <div class="row-dash">
              <div class="row-item">
                <span class="item-label">整改提交人：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.problemModifyBean.problemModifyUserName}}
                </span>
              </div>
              <div class="row-item">
                <span class="item-label">提交时间：</span>
                <span class="item-value">
                  {{rectificationDetail.detailList.problemModifyBean.modifyTime1}}
                </span>
              </div>
            </div>
            <div class="row-dash">
                <span class="item-label fl">原因分析：</span>
                <span class="item-value" style="display: block;margin-left:60px;">
                  {{rectificationDetail.detailList.problemModifyBean.causeAnalysis}}
                </span>
            </div>
            <div class="row-dash">
              <span class="multiple-rows-label">整改说明：</span>
              <span class="multiple-rows-value" style="color: #858585;">
                {{rectificationDetail.detailList.problemModifyBean.modifyDescription}}
              </span>
            </div>      
            <div class="issue-pics">
              <div class="issue-pics-title">照片</div>
              <div class="issue-pics-container">
                <img
                  ng-repeat="item in rectificationDetail.detailList.problemModifyBean.fileBeanList"
                  ng-src="{{serverIp}}/{{item.filePath}}"
                  ng-click="rectificationDetail.preview(item)"/>
              </div>
            </div>     
          </div>
        </div>
        
        <!-- 提交整改后照片 新增 -->
        <div class="item-container shadowbox"
          ng-show="rectificationDetail.detailList.problemStatus == 0">
          <div class="title">
            <div class="title-txt">
              <i class="fa fa-wrench"></i>
              <span>上传整改后照片</span>
            </div>
          </div>
          <div class="content">
            <div class="single-row">
              <div class="row-item w30">
                <span class="label">责任单位：</span>
                <span class="row-value">{{rectificationDetail.detailList.responsibilityUnit}}</span>
              </div>          
            </div>
            <div class="single-row">
              <div class="row-item">
                <span class="label">整改时间：</span>
                <input type="text" style="width: 0;height: 0;opacity: 0;">
                <input type="text" ng-datepicker
                  style="margin-left: -20px;" 
                  ng-model="rectificationDetail.rectificationList.modifyTime" />
              </div>
            </div>
            <div class="single-row">
              <div class="row-item">
                <span class="label">原因分析：</span>
                <span>以下方面存在不足</span>
                <div class="reasons">
                  <button class="sel-btn-primary"
                    ng-class="{'active': reason.active ? true : false}"
                    ng-click="reason.active = !reason.active"
                    ng-repeat="reason in rectificationDetail.reasons">{{reason.name}}</button>
                </div>          
              </div>
            </div>
            <div class="single-row">
              <div class="row-item">
                <span class="label v-middle">整改说明：</span>
                <div class="right-item-outer">
                  <textarea class="v-middle" cols="30" rows="10"
                    placeholder="请输入整改情况" 
                    ng-model="rectificationDetail.rectificationList.modifyDescription"></textarea>
                </div>
              </div>
            </div>
            <div class="single-row">
              <div class="row-item">
                <div class="right-item-outer pic-upload-container" >
                  <common-attachment-upload
                    component-id="cp2"
                    file-type="image"
                    pick-btn-id="avatar_attachment_picker1"
                    upload-url="{{fileUploadUrl.problemModifyBean}}"
                    file-list="rectificationDetail.detailList.problemModifyBean.fileBeanList"
                    is-uploading="rectificationDetail.isUploading">
                  </common-attachment-upload>
                </div> 
              </div>
            </div>
            <div class="single-row">
              <div class="right-outer"
                authorization-btn="api/securityActivities/problemModify/addProblemModify" 
                ng-click="rectificationDetail.submit()">
                <a class="pa-btn pure-btn">提交</a>
              </div>
            </div>
          </div>
        </div>

        <!-- 审批 -->
        <div class="item-container shadowbox"
          ng-if="rectificationDetail.isAuditable()">
          <div class="title">
            <div class="title-txt">
              <i class="fa fa-calendar"></i>
              <span style="margin-left: 2px">审批</span>
            </div>
          </div>
          <div class="content">
            <div class="single-row">
              <div class="right-outer approval-through">
                <input type="radio" class="sex-checkbox" value="1" 
                  ng-model="rectificationDetail.approval.checkResult" /><span>通过</span>
                <input type="radio" class="sex-checkbox" value="0" 
                  ng-model="rectificationDetail.approval.checkResult" /><span>不通过</span>
              </div>
            </div>
            <div class="single-row">
              <div class="right-outer">
                <textarea name="" id="" cols="30" rows="10" 
                  placeholder="请输入整改意见"
                  ng-model="rectificationDetail.approval.comments"></textarea>
              </div>
            </div>
          </div>
          <!-- 提交按钮 -->
          <div class="btn-outer" style="padding-left: 34%; text-align: left;"
            ng-show="rectificationDetail.detailList.problemStatus == 1">
            <a class="pa-btn"
              authorization-btn="api/securityActivities/problemModify/auditModifyProblem"
              ng-click="rectificationDetail.approvalSubmit()">
              <i class="fa fa-save"></i>
              <span class="ml5">提交</span>
            </a>
            <a class="pa-btn reset-btn" ng-click="rectificationDetail.reset()">
              <i class="fa fa-repeat"></i>
              <span class="ml5">重置</span>
            </a>
          </div>
        </div>

        <!-- 展示审批状态 -->
        <div class="item-container issue-detail-container shadowbox"
          ng-show="(rectificationDetail.approval.checkResult == '0' && rectificationDetail.detailList.problemStatus == '0') || rectificationDetail.detailList.problemStatus == '2'">
          <div class="title">
            <div class="title-txt">
              <i class="fa fa-calendar"></i>
              <span style="margin-left: 2px">审批</span>
            </div>
          </div>
          <div class="content">
            <div class="row-dash">
              <div class="row-item">
                <label class="item-label">审批人：</label>
                <span class="item-value">{{rectificationDetail.approval.auditUserName}}</span>
              </div>
              <div class="row-item">
                <label class="item-label">审批时间：</label>
                <span class="item-value">{{rectificationDetail.approval.updateTime1}}</span>
              </div>      
            </div>
            <div class="row-dash">
              <div class="row-item">
                <label class="item-label">审批结果：</label>
                <span class="item-value">
                  {{rectificationDetail.approval.checkResult == '0' ? '未通过' : 
                  rectificationDetail.approval.checkResult == '1' ? '通过' : ''}}</span>
              </div>
              <div class="row-item">
                <label class="item-label">审批意见：</label>
                <span class="item-value">{{rectificationDetail.approval.comments}}</span>
              </div>      
            </div>
          </div>
        </div>
      </div>
    </div>
  </script>

  <!-- 查看教育培训 安全技术交底 -->
  <script type="text/ng-template" id="queryInfoDisclosure">
    <div class="item-detail-dialog training-tech">
      <div class="item-detail-dialog-header">
        <div class="title-txt"
          ng-show="vm.disclosureList.trainType == 1">
          <span>查看教育培训</span>
        </div>
        <div class="title-txt"
          ng-show="vm.disclosureList.trainType == 2">
          <span>查看安全交底</span>
        </div>
      </div>
      <div class="item-detail-dialog-content">
        <form>
          <div class="row-item">
            <div class="fixed-left-label">主题：</div>
            <div class="right-value">            
              {{vm.disclosureList.theme}}
            </div>
          </div>
          <div class="row-item"
            ng-show="vm.disclosureList.trainType == 2">
            <div class="fixed-left-label">分类：</div>
            <div class="right-value">            
              {{vm.disclosureList.jdType == '1' ? '分布分项' :
              vm.disclosureList.jdType == '2' ? '工种' : ''}}
            </div>
          </div>
          <div class="row-item">
            <div class="fixed-left-label">培训时间：</div>
            <div class="right-value">
              {{vm.disclosureList.trainTime}}
            </div>
          </div>
          <div class="row-item">
            <div class="fixed-left-label">学时：</div>
            <div class="right-value">
              {{vm.disclosureList.period}}
            </div>
          </div>
          <div class="row-item">
            <div class="fixed-left-label">组织部门：</div>
            <div class="right-value">
              {{vm.disclosureList.organizationDepartmentName}}
            </div>
          </div>
          <div class="row-item">
            <div class="fixed-left-label">施工队：</div>
            <div class="right-value">
              <ul>
                <li class="con-team"
                  ng-repeat = "item in vm.disclosureList.educationTrainConTeam">
                  {{item.constructionTeamName}}
                </li>
              </ul>
            </div>
          </div>
          <div class="row-item">
            <div class="fixed-left-label">地点：</div>
            <div class="right-value">
              {{vm.disclosureList.place}}
            </div>
          </div>
          <div class="row-item">
            <div class="fixed-left-label">参加人员：</div>
            <div class="right-value">
              <div style="cursor: pointer;"
                ng-click="vm.getMore()">
                查看更多
              </div>
              <div ng-show="vm.showContent"
                ng-repeat = "team in vm.disclosureList.educationTrainConTeam">
                <div style="float: left;margin: 10px"
                  ng-repeat = "item in team.educationTrainWorker">
                  {{item.workerName}}
                </div>
              </div>
            </div>
          </div>
          <!-- 显示文件列表 -->
          <div class="avatar-attachment-upload-outer"
            style="float: left;width: 100%;padding-left: 41px;margin-top: 0;">
            <div class="file-list-outer">
              <div class="file-item" ng-repeat="item in vm.disclosureList.fileBeans">
                <span class="upload-file-name">{{item.fileName}}</span>
                <a class="pa-btn" ng-click="vm.preview(item, archiveDetail)">预览</a>
                <a class="pa-btn file-del-btn" target="_blank" 
                  ng-href="{{vm.getDownloadSrc(item)}}">
                    下载
                </a>
              </div>
            </div>
          </div> 
        </form>
      </div>
    </div>
  </script>
  
</body>
</html>